ALL: main scripts docker_run band

.PHONY: ALL clean

DIR = include
LIB = -lredis++ -lhiredis -lpthread
args = -Wall -std=c++17 -g -D QDISC -D MPLS_RULE
# -D MPLS_RULE：配置的流表使用MAC地址匹配，且源点push mpls，终点 pop mpls
# -D QDISC: 所有端口都启用 qdisc, 是否启用ATS

# HEADFILES = $(wildcard ./include/*.h)

main: main.cpp
	g++ $^ $(args) -I $(DIR) -o $@ $(LIB)

scripts: utility/scripts.cpp
	g++ $^ $(args) -I $(DIR) -o $@ -lredis++ -lhiredis -lfmt

docker_run: utility/docker_run.cpp
	g++ $^ $(args) -I $(DIR) -o $@ -lfmt

client: utility/bin/send.c
	gcc $^ -Wall -o $@

server: utility/bin/send.c
	gcc $^ -Wall -o $@

band: utility/band.cpp
	g++ $^ $(args) -o $@ -l:libhiredis.a -l:libredis++.a

clean:
	-rm -f main scripts docker_run band
